import { http } from "../utils/request"

export const getTakeOutApi =()=>{
	return http({
		method:'GET',
		url:'/prod-api/api/takeout/rotation/list'
	})
}
export const getTakeoutTypeAPI=()=>{
	return http({
		method:'GET',
		url:'/prod-api/api/takeout/theme/list',
		
	})
}
export const getRecommendAPI = ()=>{
	return http({
		method:'GET',
		url:'/prod-api/api/takeout/seller/list?recommend=Y',
	})
}
export const getShopkeeperAPI = ()=>{
	return http({
		method:'GET',
		url:'/prod-api/api/takeout/seller/near',
	})
}
export const getShopkeeperListAPI = (data)=>{
	return http({
		method:'GET',
		url:'/prod-api/api/takeout/seller/list',
		data
	})
}
export const getShopDetailAPI = (id)=>{
	return http({
		method:"GET",
		url:"/prod-api/api/takeout/seller/"+id
	})
}
export const getFoodAPI =(id)=>{
	return http({
		method:'GET',
		url:'/prod-api/api/takeout/category/list?sellerId='+id
	})
}

export const getFoodListAPI =(data)=>{
	return http({
		method:'GET',
		url:'/prod-api/api/takeout/product/list',
		data
	})
}

export const changeCollectAPI =(data)=>{
	return http({
		method:'POST',
		url:'/prod-api/api/takeout/collect',
		data
	})
}
export const getCollectAPI=(data)=>{
	return http({
		method:'GET',
		url:'/prod-api/api/takeout/collect/check',
		data
	})
}
export const cancelAPI = (id)=>{
	return http({
		method:'DELETE',
		url:'/prod-api/api/takeout/collect/'+id
	})
}

export const getCommentAPI =(id)=>{
	return http({
		method:"GET",
		url:'/prod-api/api/takeout/comment/list?sellerId='+id
	})
}

export const myCollectAPI = ()=>{
	return http({
		method:'GET',
		url:"/prod-api/api/takeout/collect/list"
	})
}